#ifndef USERLOGINSECTION_H
#define USERLOGINSECTION_H

#include "TcpConnection.h"
#include "Packet.h"
#include "TaskType.h"
#include <string>
using std::string;

namespace rocket
{

class UserLoginSection1
{
public:
    UserLoginSection1(wd::Packet& packet, wd::TcpConnectionPtr conn)
    : _conn(conn)
    , _packet(packet)
    {}
    ~UserLoginSection1() {}
    void process();

private:
    wd::TcpConnectionPtr _conn;
    wd::Packet _packet; // 存储客户端发的“用户名数据包”
};

class UserLoginSection2
{
public:
    UserLoginSection2(wd::Packet& packet, wd::TcpConnectionPtr conn)
    : _conn(conn)
    , _packet(packet)
    {}
    ~UserLoginSection2() {}
    void process();
private:
    wd::TcpConnectionPtr _conn;
    wd::Packet _packet; // 存储客户端发的“密文数据包”
};

}//end of namespace wd
#endif

